/***********************************************************************
 * Module:  ChiTietHoaDon.cs
 * Author:  Tuan Nguyen
 * Purpose: Definition of the Class ChiTietHoaDon
 ***********************************************************************/

using System;

public class ChiTietHoaDon
{
   public int SoLuongBan;
   public long GiaBan;
   public long ThanhTien;
   
   public NhanVien nhanVien;
   
   /// <pdGenerated>default parent getter</pdGenerated>
   public NhanVien GetNhanVien()
   {
      return nhanVien;
   }
   
   /// <pdGenerated>default parent setter</pdGenerated>
   /// <param>newNhanVien</param>
   public void SetNhanVien(NhanVien newNhanVien)
   {
      if (this.nhanVien != newNhanVien)
      {
         if (this.nhanVien != null)
         {
            NhanVien oldNhanVien = this.nhanVien;
            this.nhanVien = null;
            oldNhanVien.RemoveChiTietHoaDon(this);
         }
         if (newNhanVien != null)
         {
            this.nhanVien = newNhanVien;
            this.nhanVien.AddChiTietHoaDon(this);
         }
      }
   }
   public QuayHang quayHang;
   
   /// <pdGenerated>default parent getter</pdGenerated>
   public QuayHang GetQuayHang()
   {
      return quayHang;
   }
   
   /// <pdGenerated>default parent setter</pdGenerated>
   /// <param>newQuayHang</param>
   public void SetQuayHang(QuayHang newQuayHang)
   {
      if (this.quayHang != newQuayHang)
      {
         if (this.quayHang != null)
         {
            QuayHang oldQuayHang = this.quayHang;
            this.quayHang = null;
            oldQuayHang.RemoveChiTietHoaDon(this);
         }
         if (newQuayHang != null)
         {
            this.quayHang = newQuayHang;
            this.quayHang.AddChiTietHoaDon(this);
         }
      }
   }
   public Banh banh;
   
   /// <pdGenerated>default parent getter</pdGenerated>
   public Banh GetBanh()
   {
      return banh;
   }
   
   /// <pdGenerated>default parent setter</pdGenerated>
   /// <param>newBanh</param>
   public void SetBanh(Banh newBanh)
   {
      if (this.banh != newBanh)
      {
         if (this.banh != null)
         {
            Banh oldBanh = this.banh;
            this.banh = null;
            oldBanh.RemoveChiTietHoaDon(this);
         }
         if (newBanh != null)
         {
            this.banh = newBanh;
            this.banh.AddChiTietHoaDon(this);
         }
      }
   }
   public HoaDon hoaDon;
   
   /// <pdGenerated>default parent getter</pdGenerated>
   public HoaDon GetHoaDon()
   {
      return hoaDon;
   }
   
   /// <pdGenerated>default parent setter</pdGenerated>
   /// <param>newHoaDon</param>
   public void SetHoaDon(HoaDon newHoaDon)
   {
      if (this.hoaDon != newHoaDon)
      {
         if (this.hoaDon != null)
         {
            HoaDon oldHoaDon = this.hoaDon;
            this.hoaDon = null;
            oldHoaDon.RemoveChiTietHoaDon(this);
         }
         if (newHoaDon != null)
         {
            this.hoaDon = newHoaDon;
            this.hoaDon.AddChiTietHoaDon(this);
         }
      }
   }
   public DonDatHang donDatHang;
   
   /// <pdGenerated>default parent getter</pdGenerated>
   public DonDatHang GetDonDatHang()
   {
      return donDatHang;
   }
   
   /// <pdGenerated>default parent setter</pdGenerated>
   /// <param>newDonDatHang</param>
   public void SetDonDatHang(DonDatHang newDonDatHang)
   {
      if (this.donDatHang != newDonDatHang)
      {
         if (this.donDatHang != null)
         {
            DonDatHang oldDonDatHang = this.donDatHang;
            this.donDatHang = null;
            oldDonDatHang.RemoveChiTietHoaDon(this);
         }
         if (newDonDatHang != null)
         {
            this.donDatHang = newDonDatHang;
            this.donDatHang.AddChiTietHoaDon(this);
         }
      }
   }

}